﻿// -----------------------------------------------------------------------
//  <copyright file="IConnectionUserCache.cs" company="LiuliuSoft">
//      Copyright (c) 2025 66SOFT. All rights reserved.
//  </copyright>
//  <site>https://ifs.66soft.net</site>
//  <last-editor>郭明锋</last-editor>
//  <last-date>2025-09-27 22:09</last-date>
// -----------------------------------------------------------------------

namespace DaprPlus.AspNetCore.SignalR;

public interface IConnectionUserCache
{
    Task<ConnectionUser?> GetUserAsync(string userName);
    Task<string[]> GetConnectionIds(string userName);
    Task SetUser(string userName, ConnectionUser user);
    Task AddConnectionId(string userName, string connectionId);
    Task RemoveConnectionId(string userName, string connectionId);
    Task RemoveUser(string userName);
}